package com.gtw;

import com.gtw.state.ConcreteState1;
import com.gtw.state.ConcreteState2;
import com.gtw.state.Context;

public class Client {
    public static void main(String[] args) {
        //定义环境
        Context context = new Context();
        //初始状态
        context.setCurrentState(new ConcreteState2());
        //执行行为
        context.handle1();
        context.handle2();
    }
}
